﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web.Configuration;
using System.Web;
using System.Configuration;

namespace NRCP.Helpers
{
    public class SiteSettings
    {
        public const int PageSize = 10;

        public static string BaseUrl
        {
            get
            {
                string orginalUrl = HttpContext.Current.Request.Url.AbsoluteUri;
                if (HttpContext.Current.Request.Url.Query.Length > 0)
                    orginalUrl = orginalUrl.Replace(HttpContext.Current.Request.Url.Query, string.Empty);

                //return orginalUrl.Replace(HttpContext.Current.Request.Url.AbsolutePath, string.Empty) + ((HttpContext.Current.Request.ApplicationPath == "/" ? "" : HttpContext.Current.Request.ApplicationPath)) + '/';
                return orginalUrl.Replace(HttpContext.Current.Request.Url.AbsolutePath, string.Empty) + '/';
            }
        }

        public static string _CLIENT_ID
        {
            get
            {
                return ConfigurationManager.AppSettings["APP_CLIENT_ID"].ToString();
            }
            
        }


    }

    public enum PlanStatus
    {
        Pending = 0,
        Complete = 1,
        Closed=2
    }

    public enum AssesmentStatus
    {
        Satisfactory = 0,
        NotSatisfactory = 1
    }

    public enum ApprovalStatus
    {
        NotApproved=0,
        Approved=1
    }

    public enum CompletedSteps
    {
        Configure=0,
        YearlyPlan=1,
        MonthlyPlan=2,
        Complete=3
    }

    public enum NationalPlanSteps
    {
        Initiate = 0,
        YearlyPlan = 1,
        MonthlyPlan = 2,
        Complete = 3
    }
}
